﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Xml;
using System.Xml.Linq;

namespace GoogleMapsAPI
{
    public partial class frmcapnhatnhom : Form
    {
        string old;
        frmMain f;
        public frmcapnhatnhom(frmMain f, string _old)
        {
            InitializeComponent();
            this.f = f;
            old = _old;
        }

        private void btnthemdd_Click(object sender, EventArgs e)
        {
            try
            {
                Data.UpdatePlaceGroup(old, txttendiadiem.Text);
                MessageBox.Show("Succeed.");
                f.clearTree();
                f.LoadTreeView();
            }
            catch (Exception ex)
            {
                MessageBox.Show("Fail.");
            }
        }

        
    }
}
